//
//  AddShopTableViewCell6.m
//  GetPowerDBO
//
//  Created by 周博 on 2017/6/14.
//  Copyright © 2017年 BogoZhou. All rights reserved.
//

#import "AddShopTableViewCell6.h"
#import "AddShopTableViewCell5.h"
#import "BGTextView.h"

@interface AddShopTableViewCell6 ()
{
    BOOL _isYes;
}

@end

@implementation AddShopTableViewCell6

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
    _isYes = YES;
}
//点击是否同意按钮
- (IBAction)yesButtonClick:(UIButton *)sender {
    _isYes = !_isYes;
    if (_isYes) {
        [_buttonSave setBackgroundColor:kGreenColor];
        [_buttonSave setTitleColor:kWhiteColor forState:UIControlStateNormal];
        _imageViewChoose.image = [UIImage imageNamed:@"xuanzhong"];
    }else{
        [_buttonSave setBackgroundColor:kColorFrom0x(0xbebebe)];
        [_buttonSave setTitleColor:kWhiteColor forState:UIControlStateNormal];
        _imageViewChoose.image = [UIImage imageNamed:@"weixuan"];

    }
}

//点击阅读条款按钮
- (IBAction)readButtonClick:(UIButton *)sender {
    
}



//点击保存按钮
- (IBAction)sureButtonClick:(UIButton *)sender {
//    kAlert(@"点击保存");

    [[NSNotificationCenter defaultCenter] postNotificationName:@"cellSaveButtonClick" object:nil];
    
}




- (UIViewController *)viewController {
    UIResponder *next = self.nextResponder;
    do {
        //判断响应者是否为视图控制器
        if ([next isKindOfClass:[UIViewController class]]) {
            return (UIViewController *)next;
        }
        next = next.nextResponder;
    } while (next != nil);
    
    return nil;
}
- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
